package com.sgb.auction.service;

import com.sgb.auction.entity.AuctionListEntity;
import com.sgb.auction.entity.AuctionManageListEntity;
import com.sgb.auction.entity.AuctionPublishBean;
import com.sgb.auction.entity.AuctionRecordEntity;
import com.sgb.auction.entity.BiddingQueryListEntity;
import com.sgb.auction.entity.MapLongAndLatEntity;
import com.sgb.auction.entity.PublishListBean;
import com.sgb.auction.entity.RequestBean;
import com.sgb.link.entity.BrandEntity;
import com.sgb.link.entity.GetSkuEntity;
import com.sgb.link.entity.PickFilterEntity;
import com.swgk.core.base.model.entity.BaseEntity;
import com.swgk.core.base.model.entity.H5ReEntity;
import com.swgk.core.base.model.entity.ListResponse;
import com.swgk.core.base.model.factory.BaseUrlInterceptor;
import com.swgk.core.view.areapopup.AddressEntity;
import com.swgk.core.view.entity.MenuEntity;
import com.swgk.core.view.selection.CommonPopEntity;
import java.util.List;
import java.util.Map;
import okhttp3.RequestBody;
import retrofit2.Call;
import retrofit2.http.Body;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.Headers;
import retrofit2.http.Multipart;
import retrofit2.http.POST;
import retrofit2.http.PartMap;
import retrofit2.http.Query;

public interface AuctionApi {


    //竞价详情H5
    @FormUrlEncoded
    @POST("v1/app/common/getUrlSetting")
    Call<BaseEntity<H5ReEntity>> getUrlSetting(@Field("param") String param);

    //获取三级地址列表
    @GET("common/simpleArea.json")
    Call<BaseEntity<List<AddressEntity<List<AddressEntity<List<AddressEntity>>>>>>> getAddressEntityCityList();

    //项目管理获取企业列表
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @GET("v6/app/user/organizational/selectMyCompnayList")
    Call<BaseEntity<List<PublishListBean>>> getMyCompanyList();

    //项目管理获取部门列表
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @GET("v6/app/user/organizational/getDeptList")
    Call<BaseEntity<List<PublishListBean>>> getDeptList(@Query("companyId") String companyId);

    //获取地址经纬度
    @POST("v1/app/logistics/getAddressCoordinate")
    Call<BaseEntity<MapLongAndLatEntity>> getLocationLL(@Query("areaCode") String areaCode, @Query("provinceNo") String provinceNo, @Query("cityNo") String cityNo, @Query("districtNo") String districtNo);

    //上传单个文件
    @Multipart
    @POST("v1/app/common/fileUpload")
    Call<BaseEntity> uploadFile(@PartMap Map<String, RequestBody> files);

    //获取商品类型
    @GET("v1/app/member/customer/getGoodsTreeNodeByProvinceIdV2")
    Call<BaseEntity<List<MenuEntity<MenuEntity<MenuEntity>>>>> getGoodsTreeNodeByProvinceIdV2();

    //品牌-列表
    @FormUrlEncoded
    @POST("v1/app/user/goods/brandList")
    Call<BaseEntity<List<BrandEntity>>> getBrandList(@Field("id") String id, @Field("text") String text, @Field("companyId") String companyId);

    //拍卖大厅-列表
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @POST("v4/app/auction/list")
    Call<BaseEntity<ListResponse<List<AuctionListEntity>>>> getAuctionHallList(@Body RequestBean bean);

    //拍卖管理
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @POST("v3/app/auction/list")
    Call<BaseEntity<ListResponse<List<AuctionManageListEntity>>>> getAuctionManageList(@Body RequestBean bean);

    //竞买-列表
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @POST("v3/app/auction/bidder/list")
    Call<BaseEntity<ListResponse<List<BiddingQueryListEntity>>>> getBiddingQueryList(@Body RequestBean bean);

    //竞买记录-列表
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @POST("v3/app/auction/bidder/getAuctionRecord")
    Call<BaseEntity<ListResponse<List<AuctionRecordEntity>>>> getAuctionRecord(@Body RequestBean bean);

    //判断是否可以配置规格
    @FormUrlEncoded
    @POST("v1/app/user/goods/getSku")
    Call<BaseEntity<List<GetSkuEntity>>> getSku(@Field("id") String cid3);

    //新增
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @POST("v3/app/auction/add")
    Call<BaseEntity<String>> getAddAuction(@Body AuctionPublishBean bean);

    //获取单位
    @GET("v1/app/groupBuy/findUnitList")
    Call<BaseEntity<List<PublishListBean>>> getfindUnitList();

    //会员经营-会员等级
    @Headers({BaseUrlInterceptor.HEADERS_URL_MEMBER, "tokenType:pc"})
    @GET("v1/app/member/memberLevelList")
    Call<BaseEntity<List<PublishListBean>>> getMemberLevelList();

    //获取注册地区信息（用户中心-团队-信息简介界面接口）
    @GET("v1/app/site/admin/companyInfo/getAllArea")
    Call<BaseEntity<BaseEntity<List<PickFilterEntity<List<PickFilterEntity>>>>>> getMarketArea();

    //前端--拍卖列表拍卖状态筛选
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @GET("v4/app/auction/auctionStateSelect")
    Call<BaseEntity<List<PublishListBean>>> getAuctionStateSelect();

    //拍卖管理--拍卖状态筛选
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @GET("v3/app/auction/auctionStateSelect")
    Call<BaseEntity<List<CommonPopEntity>>> getAuctionState();

    //拍卖管理--撤拍
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @POST("v3/app/auction/cancel")
    Call<BaseEntity> getAuctionCancel(@Body Map bean);

    //竞买查询--拍卖状态筛选
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @GET("v3/app/auction/bidder/bidderStateSelect")
    Call<BaseEntity<List<CommonPopEntity>>> getBidderState();

    //智能关注-拍卖信息
    @Headers({BaseUrlInterceptor.HEADERS_URL_ZC, "tokenType:pc"})
    @POST("v4/app/recruit/findUserFocusAuctionList")
    Call<BaseEntity<ListResponse<List<AuctionListEntity>>>>  getfindUserFocusAuctionList(@Body RequestBean bean);
}
